<%-- 
    Document   : StoreAcc
    Created on : Jun 6, 2012, 8:12:30 PM
    Author     : praneeth
--%>
<%-- 
    Document   : StoreLogin
    Created on : Jun 4, 2012, 11:19:39 AM
    Author     : praneeth
--%>
<%@page import="java.sql.*" %>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Store Account JSP Page</title>
    </head>
    <body>    <h1>Storing!</h1>
         
        
        <%
        
        Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
            String uniq_id=request.getParameter("uniq_id");
            String firstname=request.getParameter("fname");
            String lastname=request.getParameter("lname");
            String uid=request.getParameter("uid");
            String pwd=request.getParameter("pwd");
            String cpwd=request.getParameter("cpwd");
            String fathername=request.getParameter("fathername");
            String hq=request.getParameter("hq");
            String ha=request.getParameter("ha");
            String gender=request.getParameter("gender");
            String tph_no=request.getParameter("tphno");
            String mb_no=request.getParameter("mbno");
            String e_id=request.getParameter("eid");
            String a_eid=request.getParameter("aeid");
            String addr=request.getParameter("add");
            String areaa=request.getParameter("area");
            String pinn=request.getParameter("pin");
            
     String q1="insert into AccCreation values('"+uniq_id+"','"+firstname+"','"+lastname+"','"+uid+"','"+pwd+"','"+cpwd+"','"+fathername+"','"+hq+"','"+ha+"','"+gender+"','"+tph_no+"','"+mb_no+"','"+e_id+"','"+a_eid+"','"+addr+"','"+areaa+"','"+pinn+"')";
             System.out.println(q1);
            
        Connection connection=DriverManager.getConnection("jdbc:odbc:egasdsn");
        Statement stmt =connection.createStatement();
       
        int rs=stmt.executeUpdate(q1);
            
            out.println(q1+"  "+rs);
            if(rs==1)
                out.println("inserted ");
        
        %>
    </body>
</html>
